export async function legendsTypeVerification(ctx, next) {
  try {
    ctx.verifyParams({
      typeName: { type: "string", required: true },
    });
  } catch (error) {
    return ctx.app.emit(
      "error",
      {
        code: 10001,
        message: "请输入分类名称",
        result: error,
      },
      ctx
    );
  }
  await next();
}
